import Vue from 'vue'
import Router from 'vue-router'
import Login from '@/components/Login'
import MyMenu from '@/components/Menu'
import NewBlog from '@/pages/blog/NewBlog'
import BlogList from '@/pages/blog/BlogList'
import NewLabel from '@/pages/blog/NewLabel'
import Labelist from '@/pages/blog/Labelist'
Vue.use(Router)

export default new Router({
  mode: 'history',
  routes: [
    {
      path: '/',
      name: 'Login',
      component: Login
    },{
    	path:'/index',
    	name:'MyMenu',
    	component:MyMenu,
    	children:[{
    		path:'/newblog',
    		name:'新建博文',
    		component:NewBlog
    	},{
          path:'/bloglist',
        name:'博文列表',
        component:BlogList
      },{
          path:'/newlabel',
        name:'新建标签',
        component:NewLabel
      },{
        path:'/labelist',
        name:'标签列表',
        component:Labelist
      }]
    }
  ]
})
